package com.servlet01; /**
 * @author wzm
 * @create 2023-09-19 11:46
 * project_name:javaweb2308
 */

import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.annotation.*;
import java.io.IOException;

//@WebServlet("/demo3")
public class Servlet01 extends HttpServlet {
    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        //当请求时get时执行
        System.out.println("get执行了");
    }

    @Override
    protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        //当请求时post时执行
        System.out.println("post执行了");
    }
}
